Skip to content

fix: fix possible composite key collision in StubDatabaseAdapter test utility#613

Merged
wschurman merged 1 commit into
mainfrom
05-14-fix_fix_possible_composite_key_collision_in_stubdatabaseadapter_test_utility
May 21, 2026
Merged

fix: fix possible composite key collision in StubDatabaseAdapter test utility#613
wschurman merged 1 commit into
mainfrom
05-14-fix_fix_possible_composite_key_collision_in_stubdatabaseadapter_test_utility

Conversation

@wschurman
Copy link
Copy Markdown
Member

@wschurman wschurman commented May 14, 2026

Why

The stub adapters were doing a simple : join, so it was possible for two rows to collide in the stub adapter during tests, if value has the delimiter.

How

Fix is to use JSON.stringify so that only truly same rows map to the same thing.

Test Plan

Run new tests.

Copy link
Copy Markdown
Member Author

wschurman commented May 14, 2026

@codecov
Copy link
Copy Markdown

codecov Bot commented May 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (ecf1608) to head (37e1b88).

Additional details and impacted files
@@            Coverage Diff             @@
##              main      #613    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files          109       109            
  Lines        17743     17743            
  Branches      1524       932   -592     
==========================================
  Hits         17743     17743            
Flag Coverage Δ
integration 28.61% <0.00%> (ø)
unittest 94.53% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@wschurman wschurman requested review from ide and quinlanj May 14, 2026 23:21
@wschurman wschurman marked this pull request as ready for review May 14, 2026 23:21
@wschurman wschurman force-pushed the 05-14-chore_update_comment_for_ientitymetricsadapter_for_implementors branch from 925c810 to e5683e6 Compare May 21, 2026 16:47
@wschurman wschurman force-pushed the 05-14-fix_fix_possible_composite_key_collision_in_stubdatabaseadapter_test_utility branch from fb9f279 to 7cdf562 Compare May 21, 2026 16:47
Copy link
Copy Markdown
Member Author

wschurman commented May 21, 2026

Merge activity

  • May 21, 4:55 PM UTC: A user started a stack merge that includes this pull request via Graphite.
  • May 21, 5:36 PM UTC: Graphite rebased this pull request as part of a merge.
  • May 21, 5:37 PM UTC: @wschurman merged this pull request with Graphite.

@wschurman wschurman changed the base branch from 05-14-chore_update_comment_for_ientitymetricsadapter_for_implementors to graphite-base/613 May 21, 2026 17:32
@wschurman wschurman changed the base branch from graphite-base/613 to main May 21, 2026 17:34
@wschurman wschurman force-pushed the 05-14-fix_fix_possible_composite_key_collision_in_stubdatabaseadapter_test_utility branch from 7cdf562 to 37e1b88 Compare May 21, 2026 17:35
@wschurman wschurman merged commit f300d8e into main May 21, 2026
6 checks passed
@wschurman wschurman deleted the 05-14-fix_fix_possible_composite_key_collision_in_stubdatabaseadapter_test_utility branch May 21, 2026 17:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants